﻿//  Copyright 2019 Google Inc. All Rights Reserved.
//
//  Licensed under the Apache License, Version 2.0 (the "License");
//  you may not use this file except in compliance with the License.
//  You may obtain a copy of the License at
//
//  http://www.apache.org/licenses/LICENSE-2.0
//
//  Unless required by applicable law or agreed to in writing, software
//  distributed under the License is distributed on an "AS IS" BASIS,
//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
//  See the License for the specific language governing permissions and
//  limitations under the License.

using System;
using System.Collections.Concurrent;
using System.Collections.Generic;
using System.Reflection;

namespace NtApiDotNet.Win32.Device
{
    /// <summary>
    /// Class containing well known device interface class GUIDs.
    /// </summary>
    public static class DeviceInterfaceClassGuids
    {
#pragma warning disable CS1591 // Missing XML comment for publicly visible type or member
        public static readonly Guid GUID_DEVINTERFACE_BRIGHTNESS = new Guid(0xfde5bba4, 0xb3f9, 0x46fb, 0xbd, 0xaa, 0x07, 0x28, 0xce, 0x31, 0x00, 0xb4);
        public static readonly Guid GUID_DEVINTERFACE_CDCHANGER = new Guid(0x53f56312, 0xb6bf, 0x11d0, 0x94, 0xf2, 0x00, 0xa0, 0xc9, 0x1e, 0xfb, 0x8b);
        public static readonly Guid GUID_DEVINTERFACE_CDROM = new Guid(0x53f56308, 0xb6bf, 0x11d0, 0x94, 0xf2, 0x00, 0xa0, 0xc9, 0x1e, 0xfb, 0x8b);
        public static readonly Guid GUID_DEVINTERFACE_COMPORT = new Guid(0x86e0d1e0, 0x8089, 0x11d0, 0x9c, 0xe4, 0x08, 0x00, 0x3e, 0x30, 0x1f, 0x73);
        public static readonly Guid GUID_DEVINTERFACE_DISK = new Guid(0x53f56307, 0xb6bf, 0x11d0, 0x94, 0xf2, 0x00, 0xa0, 0xc9, 0x1e, 0xfb, 0x8b);
        public static readonly Guid GUID_DEVINTERFACE_DISPLAY_ADAPTER = new Guid(0x5b45201d, 0xf2f2, 0x4f3b, 0x85, 0xbb, 0x30, 0xff, 0x1f, 0x95, 0x35, 0x99);
        public static readonly Guid GUID_DEVINTERFACE_FLOPPY = new Guid(0x53f56311, 0xb6bf, 0x11d0, 0x94, 0xf2, 0x00, 0xa0, 0xc9, 0x1e, 0xfb, 0x8b);
        public static readonly Guid GUID_DEVINTERFACE_HID = new Guid(0x4d1e55b2, 0xf16f, 0x11cf, 0x88, 0xcb, 0x00, 0x11, 0x11, 0x00, 0x00, 0x30);
        public static readonly Guid GUID_DEVINTERFACE_I2C = new Guid(0x2564aa4f, 0xdddb, 0x4495, 0xb4, 0x97, 0x6a, 0xd4, 0xa8, 0x41, 0x63, 0xd7);
        public static readonly Guid GUID_DEVINTERFACE_IMAGE = new Guid(0x6bdd1fc6, 0x810f, 0x11d0, 0xbe, 0xc7, 0x08, 0x00, 0x2b, 0xe2, 0x09, 0x2f);
        public static readonly Guid GUID_DEVINTERFACE_KEYBOARD = new Guid(0x884b96c3, 0x56ef, 0x11d1, 0xbc, 0x8c, 0x00, 0xa0, 0xc9, 0x14, 0x05, 0xdd);
        public static readonly Guid GUID_DEVINTERFACE_MEDIUMCHANGER = new Guid(0x53f56310, 0xb6bf, 0x11d0, 0x94, 0xf2, 0x00, 0xa0, 0xc9, 0x1e, 0xfb, 0x8b);
        public static readonly Guid GUID_DEVINTERFACE_MODEM = new Guid(0x2c7089aa, 0x2e0e, 0x11d1, 0xb1, 0x14, 0x00, 0xc0, 0x4f, 0xc2, 0xaa, 0xe4);
        public static readonly Guid GUID_DEVINTERFACE_MONITOR = new Guid(0xe6f07b5f, 0xee97, 0x4a90, 0xb0, 0x76, 0x33, 0xf5, 0x7b, 0xf4, 0xea, 0xa7);
        public static readonly Guid GUID_DEVINTERFACE_MOUSE = new Guid(0x378de44c, 0x56ef, 0x11d1, 0xbc, 0x8c, 0x00, 0xa0, 0xc9, 0x14, 0x05, 0xdd);
        public static readonly Guid GUID_DEVINTERFACE_NET = new Guid(0xcac88484, 0x7515, 0x4c03, 0x82, 0xe6, 0x71, 0xa8, 0x7a, 0xba, 0xc3, 0x61);
        public static readonly Guid GUID_DEVINTERFACE_OPM = new Guid(0xbf4672de, 0x6b4e, 0x4be4, 0xa3, 0x25, 0x68, 0xa9, 0x1e, 0xa4, 0x9c, 0x09);
        public static readonly Guid GUID_DEVINTERFACE_PARALLEL = new Guid(0x97f76ef0, 0xf883, 0x11d0, 0xaf, 0x1f, 0x00, 0x00, 0xf8, 0x00, 0x84, 0x5c);
        public static readonly Guid GUID_DEVINTERFACE_PARCLASS = new Guid(0x811fc6a5, 0xf728, 0x11d0, 0xa5, 0x37, 0x00, 0x00, 0xf8, 0x75, 0x3e, 0xd1);
        public static readonly Guid GUID_DEVINTERFACE_PARTITION = new Guid(0x53f5630a, 0xb6bf, 0x11d0, 0x94, 0xf2, 0x00, 0xa0, 0xc9, 0x1e, 0xfb, 0x8b);
        public static readonly Guid GUID_DEVINTERFACE_SERENUM_BUS_ENUMERATOR = new Guid(0x4d36e978, 0xe325, 0x11ce, 0xbf, 0xc1, 0x08, 0x00, 0x2b, 0xe1, 0x03, 0x18);
        public static readonly Guid GUID_DEVINTERFACE_SIDESHOW = new Guid(0x152e5811, 0xfeb9, 0x4b00, 0x90, 0xf4, 0xd3, 0x29, 0x47, 0xae, 0x16, 0x81);
        public static readonly Guid GUID_DEVINTERFACE_STORAGEPORT = new Guid(0x2accfe60, 0xc130, 0x11d2, 0xb0, 0x82, 0x00, 0xa0, 0xc9, 0x1e, 0xfb, 0x8b);
        public static readonly Guid GUID_DEVINTERFACE_TAPE = new Guid(0x53f5630b, 0xb6bf, 0x11d0, 0x94, 0xf2, 0x00, 0xa0, 0xc9, 0x1e, 0xfb, 0x8b);
        public static readonly Guid GUID_DEVINTERFACE_USB_DEVICE = new Guid(0xa5dcbf10, 0x6530, 0x11d2, 0x90, 0x1f, 0x00, 0xc0, 0x4f, 0xb9, 0x51, 0xed);
        public static readonly Guid GUID_DEVINTERFACE_USB_HOST_CONTROLLER = new Guid(0x3abf6f2d, 0x71c4, 0x462a, 0x8a, 0x92, 0x1e, 0x68, 0x61, 0xe6, 0xaf, 0x27);
        public static readonly Guid GUID_DEVINTERFACE_USB_HUB = new Guid(0xf18a0e88, 0xc30c, 0x11d0, 0x88, 0x15, 0x00, 0xa0, 0xc9, 0x06, 0xbe, 0xd8);
        public static readonly Guid GUID_DEVINTERFACE_VIDEO_OUTPUT_ARRIVAL = new Guid(0x1ad9e4f0, 0xf88d, 0x4360, 0xba, 0xb9, 0x4c, 0x2d, 0x55, 0xe5, 0x64, 0xcd);
        public static readonly Guid GUID_DEVINTERFACE_VOLUME = new Guid(0x53f5630d, 0xb6bf, 0x11d0, 0x94, 0xf2, 0x00, 0xa0, 0xc9, 0x1e, 0xfb, 0x8b);
        public static readonly Guid GUID_DEVINTERFACE_WPD = new Guid(0x6ac27878, 0xa6fa, 0x4155, 0xba, 0x85, 0xf9, 0x8f, 0x49, 0x1d, 0x4f, 0x33);
        public static readonly Guid GUID_DEVINTERFACE_WPD_PRIVATE = new Guid(0xba0c718f, 0x4ded, 0x49b7, 0xbd, 0xd3, 0xfa, 0xbe, 0x28, 0x66, 0x12, 0x11);
        public static readonly Guid GUID_DEVINTERFACE_WRITEONCEDISK = new Guid(0x53f5630c, 0xb6bf, 0x11d0, 0x94, 0xf2, 0x00, 0xa0, 0xc9, 0x1e, 0xfb, 0x8b);
        public static readonly Guid GUID_VIRTUAL_AVC_CLASS = new Guid(0x616ef4d0, 0x23ce, 0x446d, 0xa5, 0x68, 0xc3, 0x1e, 0xb0, 0x19, 0x13, 0xd0);
        public static readonly Guid GUID_61883_CLASS = new Guid(0x7ebefbc0, 0x3200, 0x11d2, 0xb4, 0xc2, 0x00, 0xa0, 0xc9, 0x69, 0x7d, 0x07);
        public static readonly Guid KSCATEGORY_ACOUSTIC_ECHO_CANCEL = new Guid(0xbf963d80, 0xc559, 0x11d0, 0x8a, 0x2b, 0x00, 0xa0, 0xc9, 0x25, 0x5a, 0xc1);
        public static readonly Guid KSCATEGORY_AUDI = new Guid(0x6994ad04, 0x93ef, 0x11d0, 0xa3, 0xcc, 0x00, 0xa0, 0xc9, 0x22, 0x31, 0x96);
        public static readonly Guid KSCATEGORY_AUDIO_DEVICE = new Guid(0xfbf6f530, 0x07b9, 0x11d2, 0xa7, 0x1e, 0x00, 0x00, 0xf8, 0x00, 0x47, 0x88);
        public static readonly Guid KSCATEGORY_AUDIO_GFX = new Guid(0x9baf9572, 0x340c, 0x11d3, 0xab, 0xdc, 0x00, 0xa0, 0xc9, 0x0a, 0xb1, 0x6f);
        public static readonly Guid KSCATEGORY_AUDIO_SPLITTER = new Guid(0x9ea331fa, 0xb91b, 0x45f8, 0x92, 0x85, 0xbd, 0x2b, 0xc7, 0x7a, 0xfc, 0xde);
        public static readonly Guid KSCATEGORY_BDA_IP_SINK = new Guid(0x71985f4a, 0x1ca1, 0x11d3, 0x9c, 0xc8, 0x00, 0xc0, 0x4f, 0x79, 0x71, 0xe0);
        public static readonly Guid KSCATEGORY_BDA_NETWORK_EPG = new Guid(0x71985f49, 0x1ca1, 0x11d3, 0x9c, 0xc8, 0x00, 0xc0, 0x4f, 0x79, 0x71, 0xe0);
        public static readonly Guid KSCATEGORY_BDA_NETWORK_PROVIDER = new Guid(0x71985f4b, 0x1ca1, 0x11d3, 0x9c, 0xc8, 0x00, 0xc0, 0x4f, 0x79, 0x71, 0xe0);
        public static readonly Guid KSCATEGORY_BDA_NETWORK_TUNER = new Guid(0x71985f48, 0x1ca1, 0x11d3, 0x9c, 0xc8, 0x00, 0xc0, 0x4f, 0x79, 0x71, 0xe0);
        public static readonly Guid KSCATEGORY_BDA_RECEIVER_COMPONENT = new Guid(0xfd0a5af4, 0xb41d, 0x11d2, 0x9c, 0x95, 0x00, 0xc0, 0x4f, 0x79, 0x71, 0xe0);
        public static readonly Guid KSCATEGORY_BDA_TRANSPORT_INFORMATION = new Guid(0xa2e3074f, 0x6c3d, 0x11d3, 0xb6, 0x53, 0x00, 0xc0, 0x4f, 0x79, 0x49, 0x8e);
        public static readonly Guid KSCATEGORY_BRIDGE = new Guid(0x085aff00, 0x62ce, 0x11cf, 0xa5, 0xd6, 0x28, 0xdb, 0x04, 0xc1, 0x00, 0x00);
        public static readonly Guid KSCATEGORY_CAPTURE = new Guid(0x65e8773d, 0x8f56, 0x11d0, 0xa3, 0xb9, 0x00, 0xa0, 0xc9, 0x22, 0x31, 0x96);
        public static readonly Guid KSCATEGORY_CLOCK = new Guid(0x53172480, 0x4791, 0x11d0, 0xa5, 0xd6, 0x28, 0xdb, 0x04, 0xc1, 0x00, 0x00);
        public static readonly Guid KSCATEGORY_COMMUNICATIONSTRANSFORM = new Guid(0xcf1dda2c, 0x9743, 0x11d0, 0xa3, 0xee, 0x00, 0xa0, 0xc9, 0x22, 0x31, 0x96);
        public static readonly Guid KSCATEGORY_CROSSBAR = new Guid(0xa799a801, 0xa46d, 0x11d0, 0xa1, 0x8c, 0x00, 0xa0, 0x24, 0x01, 0xdc, 0xd4);
        public static readonly Guid KSCATEGORY_DATACOMPRESSOR = new Guid(0x1e84c900, 0x7e70, 0x11d0, 0xa5, 0xd6, 0x28, 0xdb, 0x04, 0xc1, 0x00, 0x00);
        public static readonly Guid KSCATEGORY_DATADECOMPRESSOR = new Guid(0x2721ae20, 0x7e70, 0x11d0, 0xa5, 0xd6, 0x28, 0xdb, 0x04, 0xc1, 0x00, 0x00);
        public static readonly Guid KSCATEGORY_DATATRANSFORM = new Guid(0x2eb07ea0, 0x7e70, 0x11d0, 0xa5, 0xd6, 0x28, 0xdb, 0x04, 0xc1, 0x00, 0x00);
        public static readonly Guid KSCATEGORY_DRM_DESCRAMBLE = new Guid(0xffbb6e3f, 0xccfe, 0x4d84, 0x90, 0xd9, 0x42, 0x14, 0x18, 0xb0, 0x3a, 0x8e);
        public static readonly Guid KSCATEGORY_ENCODER = new Guid(0x19689bf6, 0xc384, 0x48fd, 0xad, 0x51, 0x90, 0xe5, 0x8c, 0x79, 0xf7, 0x0b);
        public static readonly Guid KSCATEGORY_ESCALANTE_PLATFORM_DRIVER = new Guid(0x74f3aea8, 0x9768, 0x11d1, 0x8e, 0x07, 0x00, 0xa0, 0xc9, 0x5e, 0xc2, 0x2e);
        public static readonly Guid KSCATEGORY_FILESYSTEM = new Guid(0x760fed5e, 0x9357, 0x11d0, 0xa3, 0xcc, 0x00, 0xa0, 0xc9, 0x22, 0x31, 0x96);
        public static readonly Guid KSCATEGORY_INTERFACETRANSFORM = new Guid(0xcf1dda2d, 0x9743, 0x11d0, 0xa3, 0xee, 0x00, 0xa0, 0xc9, 0x22, 0x31, 0x96);
        public static readonly Guid KSCATEGORY_MEDIUMTRANSFORM = new Guid(0xcf1dda2e, 0x9743, 0x11d0, 0xa3, 0xee, 0x00, 0xa0, 0xc9, 0x22, 0x31, 0x96);
        public static readonly Guid KSCATEGORY_MICROPHONE_ARRAY_PROCESSOR = new Guid(0x830a44f2, 0xa32d, 0x476b, 0xbe, 0x97, 0x42, 0x84, 0x56, 0x73, 0xb3, 0x5a);
        public static readonly Guid KSCATEGORY_MIXER = new Guid(0xad809c00, 0x7b88, 0x11d0, 0xa5, 0xd6, 0x28, 0xdb, 0x04, 0xc1, 0x00, 0x00);
        public static readonly Guid KSCATEGORY_MULTIPLEXER = new Guid(0x7a5de1d3, 0x01a1, 0x452c, 0xb4, 0x81, 0x4f, 0xa2, 0xb9, 0x62, 0x71, 0xe8);
        public static readonly Guid KSCATEGORY_NETWORK = new Guid(0x67c9cc3c, 0x69c4, 0x11d2, 0x87, 0x59, 0x00, 0xa0, 0xc9, 0x22, 0x31, 0x96);
        public static readonly Guid KSCATEGORY_NETWORK_CAMERA = new Guid(0xb8238652, 0xb500, 0x41eb, 0xb4, 0xf3, 0x42, 0x34, 0xf7, 0xf5, 0xae, 0x99);
        public static readonly Guid KSCATEGORY_PREFERRED_WAVEOUT_DEVICE = new Guid(0xd6c50674, 0x72c1, 0x11d2, 0x97, 0x55, 0x00, 0x00, 0xf8, 0x00, 0x47, 0x88);
        public static readonly Guid KSCATEGORY_PREFERRED_WAVEIN_DEVICE = new Guid(0xd6c50671, 0x72c1, 0x11d2, 0x97, 0x55, 0x00, 0x00, 0xf8, 0x00, 0x47, 0x88);
        public static readonly Guid KSCATEGORY_PROXY = new Guid(0x97ebaaca, 0x95bd, 0x11d0, 0xa3, 0xea, 0x00, 0xa0, 0xc9, 0x22, 0x31, 0x96);
        public static readonly Guid KSCATEGORY_QUALITY = new Guid(0x97ebaacb, 0x95bd, 0x11d0, 0xa3, 0xea, 0x00, 0xa0, 0xc9, 0x22, 0x31, 0x96);
        public static readonly Guid KSCATEGORY_REALTIME = new Guid(0xeb115ffc, 0x10c8, 0x4964, 0x83, 0x1d, 0x6d, 0xcb, 0x02, 0xe6, 0xf2, 0x3f);
        public static readonly Guid KSCATEGORY_RENDER = new Guid(0x65e8773e, 0x8f56, 0x11d0, 0xa3, 0xb9, 0x00, 0xa0, 0xc9, 0x22, 0x31, 0x96);
        public static readonly Guid KSCATEGORY_SENSOR_CAMERA = new Guid(0x24e552d7, 0x6523, 0x47f7, 0xa6, 0x47, 0xd3, 0x46, 0x5b, 0xf1, 0xf5, 0xca);
        public static readonly Guid KSCATEGORY_SPLITTER = new Guid(0x0a4252a0, 0x7e70, 0x11d0, 0xa5, 0xd6, 0x28, 0xdb, 0x04, 0xc1, 0x00, 0x00);
        public static readonly Guid KSCATEGORY_SYNTHESIZER = new Guid(0xdff220f3, 0xf70f, 0x11d0, 0xb9, 0x17, 0x00, 0xa0, 0xc9, 0x22, 0x31, 0x96);
        public static readonly Guid KSCATEGORY_SYSAUDIO = new Guid(0xa7c7a5b1, 0x5af3, 0x11d1, 0x9c, 0xed, 0x00, 0xa0, 0x24, 0xbf, 0x04, 0x07);
        public static readonly Guid KSCATEGORY_TEXT = new Guid(0x6994ad06, 0x93ef, 0x11d0, 0xa3, 0xcc, 0x00, 0xa0, 0xc9, 0x22, 0x31, 0x96);
        public static readonly Guid KSCATEGORY_TOPOLOGY = new Guid(0xdda54a40, 0x1e4c, 0x11d1, 0xa0, 0x50, 0x40, 0x57, 0x05, 0xc1, 0x00, 0x00);
        public static readonly Guid KSCATEGORY_TVAUDIO = new Guid(0xa799a802, 0xa46d, 0x11d0, 0xa1, 0x8c, 0x00, 0xa0, 0x24, 0x01, 0xdc, 0xd4);
        public static readonly Guid KSCATEGORY_TVTUNER = new Guid(0xa799a800, 0xa46d, 0x11d0, 0xa1, 0x8c, 0x00, 0xa0, 0x24, 0x01, 0xdc, 0xd4);
        public static readonly Guid KSCATEGORY_VBICODEC = new Guid(0x07dad660, 0x22f1, 0x11d1, 0xa9, 0xf4, 0x00, 0xc0, 0x4f, 0xbb, 0xde, 0x8f);
        public static readonly Guid KSCATEGORY_VIDEO = new Guid(0x6994ad05, 0x93ef, 0x11d0, 0xa3, 0xcc, 0x00, 0xa0, 0xc9, 0x22, 0x31, 0x96);
        public static readonly Guid KSCATEGORY_VIDEO_CAMERA = new Guid(0xe5323777, 0xf976, 0x4f5b, 0x9b, 0x55, 0xb9, 0x46, 0x99, 0xc4, 0x6e, 0x44);
        public static readonly Guid KSCATEGORY_VIRTUAL = new Guid(0x3503eac4, 0x1f26, 0x11d1, 0x8a, 0xb0, 0x00, 0xa0, 0xc9, 0x22, 0x31, 0x96);
        public static readonly Guid KSCATEGORY_VPMUX = new Guid(0xa799a803, 0xa46d, 0x11d0, 0xa1, 0x8c, 0x00, 0xa0, 0x24, 0x01, 0xdc, 0xd4);
        public static readonly Guid KSCATEGORY_WDMAUD = new Guid(0x3e227e76, 0x690d, 0x11d2, 0x81, 0x61, 0x00, 0x00, 0xf8, 0x77, 0x5b, 0xf1);
        public static readonly Guid KSMFT_CATEGORY_AUDIO_DECODER = new Guid(0x9ea73fb4, 0xef7a, 0x4559, 0x8d, 0x5d, 0x71, 0x9d, 0x8f, 0x04, 0x26, 0xc7);
        public static readonly Guid KSMFT_CATEGORY_AUDIO_EFFECT = new Guid(0x11064c48, 0x3648, 0x4ed0, 0x93, 0x2e, 0x05, 0xce, 0x8a, 0xc8, 0x11, 0xb7);
        public static readonly Guid KSMFT_CATEGORY_AUDIO_ENCODER = new Guid(0x91c64bd0, 0xf91e, 0x4d8c, 0x92, 0x76, 0xdb, 0x24, 0x82, 0x79, 0xd9, 0x75);
        public static readonly Guid KSMFT_CATEGORY_DEMULTIPLEXER = new Guid(0xa8700a7a, 0x939b, 0x44c5, 0x99, 0xd7, 0x76, 0x22, 0x6b, 0x23, 0xb3, 0xf1);
        public static readonly Guid KSMFT_CATEGORY_MULTIPLEXER = new Guid(0x059c561e, 0x05ae, 0x4b61, 0xb6, 0x9d, 0x55, 0xb6, 0x1e, 0xe5, 0x4a, 0x7b);
        public static readonly Guid KSMFT_CATEGORY_OTHER = new Guid(0x90175d57, 0xb7ea, 0x4901, 0xae, 0xb3, 0x93, 0x3a, 0x87, 0x47, 0x75, 0x6f);
        public static readonly Guid KSMFT_CATEGORY_VIDEO_DECODER = new Guid(0xd6c02d4b, 0x6833, 0x45b4, 0x97, 0x1a, 0x05, 0xa4, 0xb0, 0x4b, 0xab, 0x91);
        public static readonly Guid KSMFT_CATEGORY_VIDEO_EFFECT = new Guid(0x12e17c21, 0x532c, 0x4a6e, 0x8a, 0x1c, 0x40, 0x82, 0x5a, 0x73, 0x63, 0x97);
        public static readonly Guid KSMFT_CATEGORY_VIDEO_ENCODER = new Guid(0xf79eac7d, 0xe545, 0x4387, 0xbd, 0xee, 0xd6, 0x47, 0xd7, 0xbd, 0xe4, 0x2a);
        public static readonly Guid KSMFT_CATEGORY_VIDEO_PROCESSOR = new Guid(0x302ea3fc, 0xaa5f, 0x47f9, 0x9f, 0x7a, 0xc2, 0x18, 0x8b, 0xb1, 0x63, 0x02);
        public static readonly Guid GUID_DEVINTERFACE_SURFACE_VIRTUAL_DRIVE = new Guid(0x2e34d650, 0x5819, 0x42ca, 0x84, 0xae, 0xd3, 0x08, 0x03, 0xba, 0xe5, 0x05);
        public static readonly Guid GUID_USBSTOR_EHSTOR_CONTROL_INTERFACE = new Guid(0x4f40006f, 0xb933, 0x4550, 0xb5, 0x32, 0x2b, 0x58, 0xce, 0xe6, 0x14, 0xd3);
        public static readonly Guid GUID_BTHPORT_DEVICE_INTERFACE = new Guid(0x0850302a, 0xb344, 0x4fda, 0x9b, 0xe9, 0x90, 0x57, 0x6b, 0x8d, 0x46, 0xf0);
        public static readonly Guid GUID_HYPERV_VOLUME_CHECKPOINT_DEVICE_INTERFACE = new Guid(0x35fa2e29, 0xea23, 0x4236, 0x96, 0xae, 0x3a, 0x6e, 0xba, 0xcb, 0xa4, 0x40);
        public static readonly Guid GUID_HYPERV_SOCKET_DEVICE_INTERFACE = new Guid(0x999e53d4, 0x3d5c, 0x4c3e, 0x87, 0x79, 0xbe, 0xd0, 0x6e, 0xc0, 0x56, 0xe1);
        public static readonly Guid VOLMGR_VOLUME_MANAGER_GUID = new Guid(0x53f5630e, 0xb6bf, 0x11d0, 0x94, 0xf2, 0x00, 0xa0, 0xc9, 0x1e, 0xfb, 0x8b);
        public static readonly Guid GUID_DEVINTERFACE_VMLUN = new Guid(0x6f416619, 0x9f29, 0x42a5, 0xb2, 0x0b, 0x37, 0xe2, 0x19, 0xca, 0x02, 0xb0);
        public static readonly Guid GUID_DEVINTERFACE_SES = new Guid(0x1790c9ec, 0x47d5, 0x4df3, 0xb5, 0xaf, 0x9a, 0xdf, 0x3c, 0xf2, 0x3e, 0x48);
        public static readonly Guid GUID_DEVINTERFACE_SERVICE_VOLUME = new Guid(0x6ead3d82, 0x25ec, 0x46bc, 0xb7, 0xfd, 0xc1, 0xf0, 0xdf, 0x8f, 0x50, 0x37);
        public static readonly Guid GUID_DEVINTERFACE_HIDDEN_VOLUME = new Guid(0x7f108a28, 0x9833, 0x4b3b, 0xb7, 0x80, 0x2c, 0x6b, 0x5f, 0xa5, 0xc0, 0x62);
        public static readonly Guid GUID_DEVINTERFACE_UNIFIED_ACCESS_RPMB = new Guid(0x27447c21, 0xbcc3, 0x4d07, 0xa0, 0x5b, 0xa3, 0x39, 0x5b, 0xb4, 0xee, 0xe7);
#pragma warning restore CS1591 // Missing XML comment for publicly visible type or member

        /// <summary>
        /// Convert interface class GUID to a string.
        /// </summary>
        /// <param name="interface_class_guid"></param>
        /// <returns>The name of the interface class GUID.</returns>
        public static string GuidToName(Guid interface_class_guid)
        {
            return _guid_to_names.Value.GetOrAdd(interface_class_guid, string.Empty);
        }

        /// <summary>
        /// Get the list of known interface GUIDs.
        /// </summary>
        /// <returns>The list of known interface guids.</returns>
        public static IDictionary<Guid, string> GetInterfaceGuids()
        {
            Dictionary<Guid, string> dict = new Dictionary<Guid, string>();
            foreach (var f in typeof(DeviceInterfaceClassGuids).GetFields(BindingFlags.Public | BindingFlags.Static))
            {
                if (f.FieldType == typeof(Guid))
                {
                    Guid key = (Guid)f.GetValue(null);
                    dict[key] = f.Name;
                }
            }
            return dict;
        }

        private static Lazy<ConcurrentDictionary<Guid, string>> _guid_to_names 
            = new Lazy<ConcurrentDictionary<Guid, string>>(() => new ConcurrentDictionary<Guid, string>(GetInterfaceGuids()));
    }
}
